import datetime


APPID = "wxb3bb55dbf3562431"
BRANCHID = "30085"
OPENID = "oGHtg5CuVSkYIYhgmOy8OrgbOpO8"
shoppingcart_data = [
    {"title": "添加商品-无活动",
     "key": "sct_not_activity",
     "code": "0",
     "msg": "success",
     "data": {
         "activityId": None,
         "appId": APPID,
         "branchId": BRANCHID,
         "skuBuyAmount": 1,
         "skuId": 157285
     }},
    {"title": "添加商品-库存不足",
     "key": "sct_stock_deficiency",
     "code": "500009",
     "msg": "商品库存不足！",
     "data": {
         "activityId": None,
         "appId": APPID,
         "branchId": BRANCHID,
         "skuBuyAmount": 99999999,
         "skuId": 157285
     }},
    {"title": "添加商品-无库存",
     "key": "sct_stock_null",
     "code": "500008",
     "msg": "商品已售罄",
     "data": {
         "activityId": None,
         "appId": APPID,
         "branchId": BRANCHID,
         "skuBuyAmount": 1,
         "skuId": 157294
     }},
    {"title": "添加商品-下架",
     "key": "sct_goods_sold_out",
     "code": "500008",
     "msg": "商品已下架",
     "data": {
         "activityId": None,
         "appId": APPID,
         "branchId": BRANCHID,
         "skuBuyAmount": 1,
         "skuId": 157288
     }}
]

update_shoppingcart_data = [
    {"title": "修改商品数量",
     "code": "0",
     "data": 5,
     "skuBuyAmount": 5,
     "skuId": shoppingcart_data[0].get("data").get("skuId")
     },
    {"title": "修改商品数量-库存不足",
     "code": "500009",
     "data": None,
     "skuBuyAmount": 9999999,
     "skuId": shoppingcart_data[1].get("data").get("skuId")
     },
    {"title": "修改商品数量-无库存",
     "code": "500008",
     "data": None,
     "skuBuyAmount": 9999999,
     "skuId": shoppingcart_data[2].get("data").get("skuId")
     },
    {"title": "修改商品数量-商品下架",
     "code": "0",
     "data": None,
     "skuBuyAmount": 9999999,
     "skuId": shoppingcart_data[3].get("data").get("skuId")
     },

]

activity_data = [{"key": "activity_normal",
                  "title": "正常的活动",
                  "data": {
                      "commodityType": 1,
                      "spuId": 40692,
                      "activityDesc": "独秀自动化测试专用",
                      "coverImg": "https://buorgcostest2.rongyi.com/member-logo/45f54c8e59e66c186657bb9d6d0f5a0d.png",
                      "tagImg": "",
                      "startTime": datetime.datetime.now().strftime("%Y-%m-%d 00:00:00"),
                      "endTime": (datetime.datetime.now() + datetime.timedelta(days=10)).strftime("%Y-%m-%d 23:59:59"),
                      "warmupTime": datetime.datetime.now().strftime("%Y-%m-%d 00:00:00"),
                      "marketPrice": 100,
                      "sellingPrice": 100,
                      "virtualSales": 0,
                      "commodityList": [
                          {
                              "skuId": 157284,
                              "skuSpecName": "重量:1",
                              "saleStock": 100,
                              "activityStock": 50
                          }
                      ],
                      "spuName": "独秀自动化测试限时专区专用-请勿操作"
                  }},
                 {"key": "activity_not_release",
                  "title": "未发布的活动",
                  "data": {
                      "commodityType": 1,
                      "spuId": 40695,
                      "activityDesc": "独秀自动化测试专用",
                      "coverImg": "https://buorgcostest2.rongyi.com/member-logo/45f54c8e59e66c186657bb9d6d0f5a0d.png",
                      "tagImg": "",
                      "startTime": datetime.datetime.now().strftime("%Y-%m-%d 00:00:00"),
                      "endTime": (datetime.datetime.now() + datetime.timedelta(days=10)).strftime(
                          "%Y-%m-%d 23:59:59"),
                      "warmupTime": datetime.datetime.now().strftime("%Y-%m-%d 00:00:00"),
                      "marketPrice": 100,
                      "sellingPrice": 100,
                      "virtualSales": 0,
                      "commodityList": [
                          {
                              "skuId": 157287,
                              "skuSpecName": "重量:1",
                              "saleStock": 100,
                              "activityStock": 20
                          }
                      ],
                      "spuName": "独秀自动化测试限时专区专用-请勿操作"
                  }
                  },
                 {"key": "not_start",
                  "title": "未开始的活动",
                  "data": {
                      "commodityType": 1,
                      "spuId": 40694,
                      "activityDesc": "独秀自动化测试专用",
                      "coverImg": "https://buorgcostest2.rongyi.com/member-logo/45f54c8e59e66c186657bb9d6d0f5a0d.png",
                      "tagImg": "",
                      "startTime": (datetime.datetime.now() + datetime.timedelta(days=2)).strftime(
                          "%Y-%m-%d 00:00:00"),
                      "endTime": (datetime.datetime.now() + datetime.timedelta(days=10)).strftime(
                          "%Y-%m-%d 23:59:59"),
                      "warmupTime": datetime.datetime.now().strftime("%Y-%m-%d 00:00:00"),
                      "marketPrice": 100,
                      "sellingPrice": 100,
                      "virtualSales": 0,
                      "commodityList": [
                          {
                              "skuId": 157286,
                              "skuSpecName": "重量:1",
                              "saleStock": 100,
                              "activityStock": 20
                          }
                      ],
                      "spuName": "独秀自动化测试限时专区专用-请勿操作"
                  }
                  },
                 {"key": "activity_finish",
                  "title": "已结束活动",
                  "data": {
                      "commodityType": 1,
                      "spuId": 40693,
                      "activityDesc": "独秀自动化测试专用",
                      "coverImg": "https://buorgcostest2.rongyi.com/member-logo/45f54c8e59e66c186657bb9d6d0f5a0d.png",
                      "tagImg": "",
                      "startTime": datetime.datetime.now().strftime("%Y-%m-%d 00:00:00"),
                      "endTime": (datetime.datetime.now() + datetime.timedelta(days=10)).strftime(
                          "%Y-%m-%d 23:59:59"),
                      "warmupTime": datetime.datetime.now().strftime("%Y-%m-%d 00:00:00"),
                      "marketPrice": 100,
                      "sellingPrice": 100,
                      "virtualSales": 0,
                      "commodityList": [
                          {
                              "skuId": 157285,
                              "skuSpecName": "重量:1",
                              "saleStock": 100,
                              "activityStock": 20
                          }
                      ],
                      "spuName": "独秀自动化测试限时专区专用-请勿操作"
                  }
                  }]


